<?php
    
    @$id=$_GET['id'];    
    $query = "SELECT * FROM Pelnomocnictwo WHERE `idPelnomocnictwa`=$id";
    $result = mysql_query($query) or die('zapytanie niudane: '.mysql_error());
    $result = mysql_fetch_row($result);

    $query="SELECT * FROM Klient";
    $wynik=mysql_query($query) or die('zapytanie niudane: '.mysql_error());

    echo "<form action=\"skrypty/peln/akcje/wstawPeln.php?login=$login&opcja=mod&id=$id\" method=\"post\">
            Klient: <BR><select name=\"klient\">";
            while($line = mysql_fetch_array($wynik, MYSQL_NUM))
                echo "<option value=\"$line[0]\">$line[1] $line[2]</option>";
            echo "</select><BR>";
			echo "Opis: <br> <textarea name=\"opis\" rows=\"20\" cols=\"90\">{$result[2]}</textarea> <br>

			<input type=\"submit\" value=\"Wyślij\">
         </form>";
?>
